<?php

namespace Ifmia\AppBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Ifmia\AppBundle\Entity\Session
 *
 * @ORM\Table()
 * @ORM\Entity(repositoryClass="Ifmia\AppBundle\Entity\SessionRepository")
 */
class Session
{
	/**
	 * @ORM\ManyToOne(targetEntity="Ifmia\AppBundle\Entity\Formation")
	 */
    Private $formation;
    
    /**
     * @ORM\ManyToOne(targetEntity="Ifmia\AppBundle\Entity\TypologieSession")
     */
    Private $typologieSession;
	
	
    /**
     * @var integer $id
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var string $codeSession
     *
     * @ORM\Column(name="codeSession", type="string", length=150,nullable=true)
     */
    private $codeSession;

    /**
     * @var integer $nombreHeureSession
     *
     * @ORM\Column(name="nombreHeureSession", type="integer")
     */
    private $nombreHeureSession;

    /**
     * @var integer $nombreInscrit
     *
     * @ORM\Column(name="nombreInscrit", type="integer",nullable=true)
     */
    private $nombreInscrit;

    /**
     * @var datetime $dateDebutSession
     *
     * @ORM\Column(name="dateDebutSession", type="datetime")
     */
    private $dateDebutSession;

    /**
     * @var datetime $dateFinSession
     *
     * @ORM\Column(name="dateFinSession", type="datetime")
     */
    private $dateFinSession;

    /**
     * @var datetime $datePlanificationSession
     *
     * @ORM\Column(name="datePlanificationSession", type="datetime",nullable=true)
     */
    private $datePlanificationSession;

    /**
     * @var date $dateClotureSession
     *
     * @ORM\Column(name="dateClotureSession", type="date",nullable=true)
     */
    private $dateClotureSession;

    /**
     * @var date $dateCreationSession
     *
     * @ORM\Column(name="dateCreationSession", type="date",nullable=true)
     */
    private $dateCreationSession;
    
    /**
     * @var date $dateAnnulationSession
     *
     * @ORM\Column(name="dateAnnulationSession", type="date",nullable=true)
     */
    private $dateAnnulationSession;

    /**
     * @var string $etatSession
     *
     * @ORM\Column(name="etatSession", type="string", length=20,nullable=true)
     */
    private $etatSession;

    /**
     * @var integer $nombrePlacePerdue
     *
     * @ORM\Column(name="nombrePlacePerdue", type="integer",nullable=true)
     */
    private $nombrePlacePerdue;

    /**
     * @var integer $tauxAbsence
     *
     * @ORM\Column(name="tauxAbsence", type="integer",nullable=true)
     */
    private $tauxAbsence;

    /**
     * @var integer $tauxRemplissage
     *
     * @ORM\Column(name="tauxRemplissage", type="integer",nullable=true)
     */
    private $tauxRemplissage;


    /**
     * Get id
     *
     * @return integer 
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set codeSession
     *
     * @param string $codeSession
     */
    public function setCodeSession($codeSession)
    {
        $this->codeSession = $codeSession;
    }

    /**
     * Get codeSession
     *
     * @return string 
     */
    public function getCodeSession()
    {
        return $this->codeSession;
    }

    /**
     * Set nombreHeureSession
     *
     * @param integer $nombreHeureSession
     */
    public function setNombreHeureSession($nombreHeureSession)
    {
        $this->nombreHeureSession = $nombreHeureSession;
    }

    /**
     * Get nombreHeureSession
     *
     * @return integer 
     */
    public function getNombreHeureSession()
    {
        return $this->nombreHeureSession;
    }

    /**
     * Set nombreInscrit
     *
     * @param integer $nombreInscrit
     */
    public function setNombreInscrit($nombreInscrit)
    {
        $this->nombreInscrit = $nombreInscrit;
    }

    /**
     * Get nombreInscrit
     *
     * @return integer 
     */
    public function getNombreInscrit()
    {
        return $this->nombreInscrit;
    }

    /**
     * Set dateDebutSession
     *
     * @param datetime $dateDebutSession
     */
    public function setDateDebutSession($dateDebutSession)
    {
        $this->dateDebutSession = $dateDebutSession;
    }

    /**
     * Get dateDebutSession
     *
     * @return datetime 
     */
    public function getDateDebutSession()
    {
        return $this->dateDebutSession;
    }

    /**
     * Set dateFinSession
     *
     * @param datetime $dateFinSession
     */
    public function setDateFinSession($dateFinSession)
    {
        $this->dateFinSession = $dateFinSession;
    }

    /**
     * Get dateFinSession
     *
     * @return datetime 
     */
    public function getDateFinSession()
    {
        return $this->dateFinSession;
    }

    /**
     * Set datePlanificationSession
     *
     * @param datetime $datePlanificationSession
     */
    public function setDatePlanificationSession($datePlanificationSession)
    {
        $this->datePlanificationSession = $datePlanificationSession;
    }

    /**
     * Get datePlanificationSession
     *
     * @return datetime 
     */
    public function getDatePlanificationSession()
    {
        return $this->datePlanificationSession;
    }

    /**
     * Set dateClotureSession
     *
     * @param date $dateClotureSession
     */
    public function setDateClotureSession($dateClotureSession)
    {
        $this->dateClotureSession = $dateClotureSession;
    }

    /**
     * Get dateClotureSession
     *
     * @return date 
     */
    public function getDateClotureSession()
    {
        return $this->dateClotureSession;
    }

    /**
     * Set dateCreationSession
     *
     * @param date $dateCreationSession
     */
    public function setDateCreationSession($dateCreationSession)
    {
        $this->dateCreationSession = $dateCreationSession;
    }

    /**
     * Get dateCreationSession
     *
     * @return date 
     */
    public function getDateCreationSession()
    {
        return $this->dateCreationSession;
    }

    /**
     * Set etatSession
     *
     * @param string $etatSession
     */
    public function setEtatSession($etatSession)
    {
        $this->etatSession = $etatSession;
    }

    /**
     * Get etatSession
     *
     * @return string 
     */
    public function getEtatSession()
    {
        return $this->etatSession;
    }

    /**
     * Set nombrePlacePerdue
     *
     * @param integer $nombrePlacePerdue
     */
    public function setNombrePlacePerdue($nombrePlacePerdue)
    {
        $this->nombrePlacePerdue = $nombrePlacePerdue;
    }

    /**
     * Get nombrePlacePerdue
     *
     * @return integer 
     */
    public function getNombrePlacePerdue()
    {
        return $this->nombrePlacePerdue;
    }

    /**
     * Set tauxAbsence
     *
     * @param integer $tauxAbsence
     */
    public function setTauxAbsence($tauxAbsence)
    {
        $this->tauxAbsence = $tauxAbsence;
    }

    /**
     * Get tauxAbsence
     *
     * @return integer 
     */
    public function getTauxAbsence()
    {
        return $this->tauxAbsence;
    }

    /**
     * Set tauxRemplissage
     *
     * @param integer $tauxRemplissage
     */
    public function setTauxRemplissage($tauxRemplissage)
    {
        $this->tauxRemplissage = $tauxRemplissage;
    }

    /**
     * Get tauxRemplissage
     *
     * @return integer 
     */
    public function getTauxRemplissage()
    {
        return $this->tauxRemplissage;
    }

    /**
     * Set formation
     *
     * @param Ifmia\AppBundle\Entity\Formation $formation
     */
    public function setFormation(\Ifmia\AppBundle\Entity\Formation $formation)
    {
        $this->formation = $formation;
    }

    /**
     * Get formation
     *
     * @return Ifmia\AppBundle\Entity\Formation 
     */
    public function getFormation()
    {
        return $this->formation;
    }
    
  

    /**
     * Set typologieSession
     *
     * @param Ifmia\AppBundle\Entity\TypologieSession $typologieSession
     */
    public function setTypologieSession(\Ifmia\AppBundle\Entity\TypologieSession $typologieSession)
    {
        $this->typologieSession = $typologieSession;
    }

    /**
     * Get typologieSession
     *
     * @return Ifmia\AppBundle\Entity\TypologieSession 
     */
    public function getTypologieSession()
    {
        return $this->typologieSession;
    }
    
    
    public function generateCode()
    {
    	return $this->getId()."-".$this->getDateDebutSession()."-".$this->getFormation();
    }
    
    

    /**
     * Set dateAnnulationSession
     *
     * @param date $dateAnnulationSession
     */
    public function setDateAnnulationSession($dateAnnulationSession)
    {
        $this->dateAnnulationSession = $dateAnnulationSession;
    }

    /**
     * Get dateAnnulationSession
     *
     * @return date 
     */
    public function getDateAnnulationSession()
    {
        return $this->dateAnnulationSession;
    }
}